package games.gameObjects.towers;

import gameUtils.Coordinate;
import gameUtils.GameMath;
import games.gameObjects.ShootingType;

import java.awt.Point;
import java.io.IOException;

import pt.iul.poo.image.SimpleImage;

public class Tower1 extends Tower{

	public static final int PRIORITY = 20;
	public static final int COST = 5;
	public static final int DAMAGE = 1;
	public static final int RANGE = 1;
	public static final String NAME = "Turret";
	
	private SimpleImage img;
	/**
	 * Default Constructor of the Object Tower1
	 * Leaf of <<abstract>> class Tower 
	 * @param Coordinate
	 * @param priority
	 */
	public Tower1(final Coordinate c){
		super(c,PRIORITY,NAME,DAMAGE,RANGE,COST);
		try {
			Point p = GameMath.convertToPoint(c);
			img = new SimpleImage("Images//Tower1.png",(int)p.getX(),(int)p.getY(),PRIORITY);
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
	
	@Override
	public SimpleImage getImage() {
		return this.img;
	}
	@Override
	public ShootingType getShootingType() {
		return ShootingType.LAND;
	}
	@Override
	public TowerType getTowerType() {
		return TowerType.ONE;
	}
	
}
